package com.gopay.cron.web.util;

import java.util.ResourceBundle;

/**
 * 属性工具类,将portal项目常用配置文件进行缓存
 * 
 * @PropertyUtil.java
 * @author fanghw
 * @2013-1-18 下午3:17:12 www.gopay.com.cn Inc.All rights reserved.
 */
public class PropertiesUtil {

    /**
     * portal.properties文件对应的bundle
     */
    private static ResourceBundle portalBundle;

    static {
        // 绑定类路径下的文件properties/portal.properties
        portalBundle = ResourceBundle.getBundle("properties/cron");
    }

    /**
     * 根据key从portal.properties文件中获取value值
     * 
     * @param key
     * @return
     */
    public static String getValue(String key) {
        return portalBundle.getString(key);
    }
}
